package com.xuanwei.dao.entity;

import java.math.BigDecimal;

import com.baomidou.mybatisplus.annotation.IdType;

import java.time.LocalDate;

import com.baomidou.mybatisplus.annotation.TableId;

import java.time.LocalDateTime;

import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableField;

import java.io.Serializable;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 *
 * </p>
 *
 * @author mjy
 * @since 2019-08-19
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class XwUserCoupon implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 用户ID
     */
    @TableField("user_id")
    private Integer userId;

    /**
     * 优惠券ID
     */
    @TableField("coupon_id")
    private Integer couponId;

    /**
     * 优惠券标题
     */
    @TableField("coupon_title")
    private String couponTitle;

    /**
     * 优惠券金额
     */
    @TableField("coupon_amount")
    private BigDecimal couponAmount;

    /**
     * 优惠券类型 0满减型 1无门栏 2指定商品
     */
    @TableField("coupon_type")
    private Integer couponType;

    /**
     * 限制类型 0 无限制 1限制活动 2限制商品
     */
    @TableField("coupon_limit_type")
    private Integer couponLimitType;

    /**
     * 活动ID或商品ID
     */
    @TableField("coupon_obj_id")
    private Integer couponObjId;


    /**
     * 门栏金额
     */
    @TableField("coupon_condition_amount")
    private BigDecimal couponConditionAmount;




    /**
     * 结束时间
     */
    @TableField("coupon_expire_time")
    private LocalDateTime couponExpireTime;

    /**
     * 优惠券说明
     */
    @TableField("coupon_explain")
    private String couponExplain;

    /**
     * 0没使用1已使用
     */
    @TableField("status")
    private Integer status;

    /**
     * 领取时间
     */
    @TableField("obtain_time")
    private LocalDateTime obtainTime;

    /**
     * 0正常1删除
     */
    @TableField("delete_flag")
    @TableLogic
    private Integer deleteFlag;


}
